<template>
    <figure class="figure">
        <img width="50px" height="50px" :src="imgSrc">
        <div class="discuss-content-block">
            <p>{{ item.content }}</p>
            <span><Icon size="20" type="ios-person-outline" />&nbsp;&nbsp;&nbsp;{{ item.userName }}</span>
            <span style="margin-left:10px">{{ creatTime }}</span>
        </div>
    </figure>
</template>

<script>
import { formatData } from '@/utils/format';
import { domain } from '@/utils/host';
export default {
    name:"discussList",
    props:['item'],
    computed:{
        imgSrc(){
            return `${domain}/fdl/preImages/${this.item.headerPath}`
        },
        creatTime(){
            return formatData(this.item.create_time)
        }
    },
}
</script>

<style lang="scss" scoped>
    .figure{
        display: flex;
        align-items: center;
        padding: 20px 0;
        border-bottom:1px solid rgba(217,219,221,1);
        img{
            width:50px;
            height: 50px;
            display: inline-block;
            border-radius: 50%;
        }
        .discuss-content-block{
            flex: 1;
            margin-left:20px;
            p{
                font-size:18px;
                font-weight:bold;
                color:rgba(51,51,51,1);
            }
            span{
                font-size:12px;
                font-weight:400;
                color:rgba(153,153,153,1);
            }
        }
    }
</style>